import { defineConfig } from 'vite'
import vue from '@vitejs/plugin-vue'
import { resolve } from 'path'

// https://vite.dev/config/
export default defineConfig({
  base: '/vue3-kj/', // 注意斜杠
  plugins: [vue()],
  resolve: {
    alias: {
      '@': resolve(__dirname, 'src')
    }
  },
  server: {
    port: 5280,
    proxy: {
      // '/api/text-processing': {
      //   target: 'http://192.168.100.62:7861',
      //   changeOrigin: true,
      //   rewrite: (path) => path.replace(/^\/api\/text-processing/, '')
      // }
    }
  }
})
